// 修改教学班信息
<template>
  <div id="edit-teach-class-info" class="manual-entry-container">
    <div>
      <ul>
        <li>
          <span class="active">课程名称</span>
          <span>{{ courseName }}</span>
          <span class="active">培养层次</span>
          <span>{{ eduLevelName }}</span>
        </li>
        <li>
          <span class="active">教学班名<span>*</span></span>
          <span>
            <el-input size="small" v-model="teachingClassName"></el-input>
          </span>
          <span class="active">修习类型</span>
          <span>{{ subjectType }}</span>
        </li>
        <li>
          <span class="active">学时<span>*</span></span>
          <span>{{ totalHours }}</span>
          <span class="active">理论学时<span>*</span></span>
          <span>{{ teachingHours }}</span>
        </li>
        <li>
          <span class="active">实践学时<span>*</span></span>
          <span>{{ practiceHours }}</span>
          <span class="active">学分<span>*</span></span>
          <span>{{ credit }}</span>
        </li>
        <li>
          <span class="active">教学课主讲</span>
          <span
            ><span
              style="color: #004ca7"
              v-for="item in jxkZhujiang"
              :key="item.id"
              >{{ item.xm }}&nbsp;&nbsp;</span
            ><img
              src="../../../../../assets/assessment/icon-plan-record-detail.png"
              width="20"
              height="20"
              @click="editSpeaker('jxkzj')"
          /></span>
          <span class="active">教学课助教</span>
          <span
            ><span
              style="color: #004ca7"
              v-for="item in jxkZhujiao"
              :key="item.id"
              >{{ item.xm }}&nbsp;&nbsp;</span
            ><img
              src="../../../../../assets/assessment/icon-plan-record-detail.png"
              width="20"
              height="20"
              @click="editSpeaker('zj2')"
          /></span>
        </li>
        <li>
          <span class="active">考核方式<span>*</span></span>
          <span
            ><el-select
              v-model="khfs"
              placeholder="请选择"
              size="mini"
              style="width: 200px"
            >
              <el-option
                v-for="(item, index) in khfsList"
                :key="item.id"
                :label="item.name"
                :value="item.id"
              >
              </el-option> </el-select
          ></span>
          <span class="active">分制<span>*</span></span>
          <span>
            <el-select
              v-model="pointsSystem"
              placeholder="请选择"
              size="mini"
              style="width: 200px"
            >
              <el-option
                v-for="(item, index) in pointsSystemList"
                :key="item.id"
                :label="item.name"
                :value="item.id"
              >
              </el-option>
            </el-select>
          </span>
        </li>
        <li>
          <span class="active">课下作业成绩所占比例</span>
          <span
            ><el-input size="small" v-model="homeworkRatio"></el-input
          ></span>
          <span class="active">课堂测试成绩所占比例</span>
          <span><el-input size="small" v-model="hskeRatio"></el-input></span>
        </li>
        <li>
          <span class="active">期中考试成绩所占比例</span>
          <span><el-input size="small" v-model="midExamRatio"></el-input></span>
          <span class="active">课终考核成绩所占比例</span>
          <span
            ><el-input size="small" v-model="finalExamRetio"></el-input
          ></span>
        </li>
        <li>
          <span class="active">授课方式</span>
          <span>
            <div style="display: flex; justify-content: space-between">
              <el-select
                v-model="teachingMethod"
                placeholder="请选择"
                size="mini"
                style="width: 200px"
              >
                <el-option
                  v-for="(item, index) in teachingMethodList"
                  :key="item.id"
                  :label="item.name"
                  :value="item.id"
                >
                </el-option>
              </el-select>
            </div>
          </span>
          <span class="active">教学场所类型</span>
          <span>
            <div style="display: flex; justify-content: space-between">
              <el-select
                v-model="jxcslx"
                placeholder="请选择"
                size="mini"
                style="width: 200px"
              >
                <el-option
                  v-for="(item, index) in jxcslxList"
                  :key="item.id"
                  :label="item.name"
                  :value="item.id"
                >
                </el-option>
              </el-select>
            </div>
          </span>
        </li>
        <li>
          <span class="active">课程负责人</span>
          <span>
            <div style="display: flex; justify-content: space-between">
              <el-select
                v-model="kcfzr"
                placeholder="请选择"
                size="mini"
                style="width: 200px"
              >
                <el-option
                  v-for="(item, index) in kcfzrList"
                  :key="item.id"
                  :label="item.xm"
                  :value="item.id"
                >
                </el-option>
              </el-select>
            </div>
          </span>
          <span class="active">教学场地场所</span>
          <span
            ><span
              style="color: #004ca7"
              v-for="item in jxcdcsList"
              :key="item.id"
              >{{ item.cdmc }}&nbsp;&nbsp;</span
            ><img
              src="../../../../../assets/assessment/icon-plan-record-detail.png"
              width="20"
              height="20"
              @click="selectJXCDCS()"
          /></span>
        </li>
        <li>
          <span class="active" style="height: 200px">排课要求</span>
          <span style="height: 200px"
            ><el-input
              size="small"
              type="textarea"
              :rows="6"
              v-model="arrangeReq"
            ></el-input
          ></span>
        </li>
      </ul>
    </div>

    <div style="margin: 30px auto; text-align: center">
      <el-button
        type="success"
        plain
        size="mini"
        @click="submitInfo()"
        style="margin-right: 150px"
        >确定</el-button
      >
      <el-button type="danger" plain size="mini" @click="cancel()">取消</el-button>
    </div>
    <el-dialog
      :title="dialogType == 'jxkzj' ? '教学课主讲' : '教学课助教'"
      :visible.sync="showSpeakerDialog"
      width="1400px"
      style="border: 0px; height: auto"
      class="jxkzj"
    >
      <div>
        <el-row>
          <el-col :span="4">
            <el-tree
              default-expand-all
              :data="data"
              :props="defaultProps"
              @node-click="handleNodeClick"
              style="
                color: #004ca7;
                margin: 20px 40px;
                font-weight: bold;
                background: #f0f2f5;
              "
            ></el-tree>
          </el-col>
          <el-col :span="20" class="border-left">
            <div
              class="assessment-container"
              style="
                width: 100%;
                padding: 20px;
                border-left: 1px solid #004ca7;
                pading-left: 0px;
              "
            >
              <div class="search-container">
                <div class="search-container-left">
                  <div class="search-container-item">
                    <el-input
                      placeholder="关键字搜索"
                      style="width: 50%"
                      size="small"
                      v-model="queryKey"
                    ></el-input>
                  </div>
                  <div class="search-button" @click="queryTeacherInfo()">
                    <img
                      src="../../../../../assets/assessment/icon-search.png"
                      alt=""
                    />
                    <span>查询</span>
                  </div>
                </div>
              </div>
              <div class="search-container">
                <div class="search-container-left">
                  <div
                    class="search-container-item"
                    style="
                      margin: 5px 0;
                      width: 100%;
                      overflow: auto;
                      height: 25px;
                    "
                  >
                    <span>已选人员:</span>
                    <el-tag
                      size="small"
                      v-for="(tag, inx) in classSelectList"
                      :key="tag.xm"
                      closable
                      type="info"
                      hit
                      @close="handleClose(tag, inx)"
                    >
                      {{ tag.xm }}
                    </el-tag>
                  </div>
                </div>
              </div>
              <div class="table-container" style="width: 100%; border: 0px">
                <el-table
                  ref="multipleTable"
                  :data="speakerTableData"
                  border
                  class="table-data"
                  row-class-name="row-class"
                  cell-class-name="cell-class"
                  header-row-class-name="header-row-class"
                  header-cell-class-name="header-cell-class"
                  style="height: 330px; overflow-y: auto"
                  @selection-change="handleSelectionChange"
                >
                  <el-table-column
                    align="center"
                    type="selection"
                    width="80"
                  ></el-table-column>
                  <el-table-column
                    prop="gzbm"
                    label="教研室"
                    align="center"
                  ></el-table-column>
                  <el-table-column
                    prop="xm"
                    label="姓名"
                    align="center"
                  ></el-table-column>
                </el-table>
              </div>
            </div>
          </el-col>
        </el-row>
      </div>
      <span slot="footer" class="dialog-footer">
        <el-button
          type="warning"
          size="mini"
          plain
          style="margin-right: 50px"
          @click="submitSelectTeacher()"
          >确 定</el-button
        >
        <el-button type="danger" size="mini" plain @click="cancelSelect"
          >取 消</el-button
        >
      </span>
    </el-dialog>

    <el-dialog
      title="选择教学场地"
      :visible.sync="selectRomePlaceDialog"
      width="1400px"
      style="border: 0px; height: auto"
      class="xz_jxkzj"
    >
      <select-class-room
        :source="'dialog'"
        @savePlaceInfo="savePlaceInfo"
        @cancelPlaceInfo="cancelPlaceInfo"
      ></select-class-room>
    </el-dialog>
  </div>
</template>

<script>
import selectClassRoom from "../../elective/selectClassRoom.vue";
import ButtonItem from "@/components/ButtonItem.vue";
import {
  jxbgl_query_teaching_class_detail,
  jxbgl_teaching_save,
  jxbgl_teaching_update,
  jxbgl_query_teacher_list,
  queryCommonDept,
  queryCommonDeptByCategory,
  queryCommonKhfsType,
  queryCommonFzType,
  queryCommonSkfsType,
  queryCommonCdcsType,
  jxbgl_query_szIndex
} from "@/api/trainingManagement/place.js";
export default {
  components: {
    ButtonItem,
    selectClassRoom,
  },
  data() {
    return {
      selectRomePlaceDialog: false, //选择教学场地弹窗
      dialogTitle: "教学课主讲", //弹窗标题
      queryKey: "", //搜索关键字
      defaultProps: {
        children: "children",
        label: "name",
      },
      data: [], //部门树列表
      speakerTableData: [], //讲师表格数据
      showSpeakerDialog: false,
      khfs: "",
      khfsList: [], //考核方式
      jxcslx: "",
      jxcslxList: [], //教学场所类型
      kcfzr: "",
      kcfzrList: [], //课程负责人
      jxcdcsList: [], //教学舱底场所

      id: "",
      courseName: "", //课程名称
      eduLevel: "", //培养层次
      eduLevelName: '',
      teachingClassName: "", //教学班名
      subjectType: "", //修习类型
      totalHours: "", //学时
      teachingHours: "", //理论学时
      practiceHours: "", //实践学时
      credit: "", //学分
      pointsSystem: "", //分制
      homeworkRatio: "", // 课下作业成绩所占比例
      hskeRatio: "", //课堂测试成绩所占比例
      midExamRatio: "", //期中考试成绩所占比例
      finalExamRetio: "", //课终考核成绩所占比例
      teachingMethod: "", //授课方式
      arrangeReq: "", //排课要求

      pointsSystemList: [{ label: "全部", value: "全部" }], //分制列表
      teachingMethodList: [{ label: "全部", value: "全部" }], //授课方式
      classSelectList: [], //选中的教师
      jxkZhujiang: [], //教学课主讲
      jxkZhujiao: [], //教学课助教
      selectTreeNode: {}, //点击树节点
      info_type: "", //类型

      kcid: "",
      xueqi: "",
      nj: this.$route.query.nj,
      kcbh: "",
      courseno: "",
      staffRoom: "",
    };
  },
  mounted() {
    this.kcid = this.$route.query.kcid;
    this.xueqi = this.$route.query.xueqi;
    this.nj = this.$route.query.nj || this.nj;
    this.kcbh = this.$route.query.kcbh;
    this.id = this.$route.query.id;
    this.info_type = this.$route.query.type;
    this.queryKcById();
    // if (this.info_type == "add") {
    //   this.queryKcById();
    // } else {
    //   this.queryKcById();
    //   this.queryEditInfo();
    // }
    this.queryCommonKhfsType();
    this.queryCommonFzType();
    this.queryCommonSkfsType();
    this.queryCommonCdcsType();
  },
  methods: {
    // 查询教学班管理数据
    async queryKcById() {
      var kcid = this.kcid;
      var nj = this.nj;
      var xueqi = this.xueqi;
      var kcbh = this.kcbh;
      jxbgl_query_szIndex(kcid,nj,xueqi, kcbh).then(res=>{
        if (res.data.code == 200) {
          var courseData = res.data.data.courseInfo;
          this.courseName = courseData.courseName;
          this.eduLevel = courseData.eduLevel;
          this.eduLevelName = courseData.eduLevelName;
          this.subjectType = courseData.subjectType;
          this.totalHours = courseData.totalHours;
          this.teachingHours = courseData.teachingHours;
          this.practiceHours = courseData.practiceHours;
          this.credit = courseData.credit;
          this.courseno = courseData.courseCode;
          this.staffRoom = courseData.teachingClassName;
          this.pointsSystem = courseData.pointsSystem;
          this.khfs = courseData.khfs;
        }
      }).then(()=>{
        if (this.info_type != "add") {
          this.queryEditInfo();
        }
      })
    },
    // 保存教学场地
    savePlaceInfo(data) {
      this.jxcdcsList = data;
      console.log(data, "=====");
      this.cancelPlaceInfo();
    },
    cancelPlaceInfo() {
      this.selectRomePlaceDialog = false;
    },
    // 打开教学场地场所
    selectJXCDCS() {
      this.selectRomePlaceDialog = true;
    },
    async queryCommonKhfsType(params) {
      const res = await queryCommonKhfsType(params);
      if (res.data.code == 200) {
        this.khfsList = res.data.data;
      }
    },
    async queryCommonFzType(params) {
      const res = await queryCommonFzType(params);
      if (res.data.code == 200) {
        this.pointsSystemList = res.data.data;
      }
    },
    async queryCommonSkfsType(params) {
      const res = await queryCommonSkfsType(params);
      if (res.data.code == 200) {
        this.teachingMethodList = res.data.data;
      }
    },
    async queryCommonCdcsType(params) {
      const res = await queryCommonCdcsType(params);
      if (res.data.code == 200) {
        this.jxcslxList = res.data.data;
      }
    },
    // 数组去重
    arrSet(arr) {
      let obj = {};
      arr = arr.reduce((newArr, next) => {
        obj[next.id] ? "" : (obj[next.id] = true && newArr.push(next));
        return newArr;
      }, []);
      return arr;
    },
    // 选择讲师确定
    submitSelectTeacher() {
      if (this.dialogType == "jxkzj") {
        // 教学课主讲
        this.jxkZhujiang = this.classSelectList;
      } else {
        // 助教
        this.jxkZhujiao = this.classSelectList;
      }
      var newArr = this.jxkZhujiang.concat(this.jxkZhujiao);
      this.kcfzrList = this.arrSet(newArr);
      this.showSpeakerDialog = false;
    },
    cancelSelect() {
      this.showSpeakerDialog = false;
      this.classSelectList = [];
      this.$refs.multipleTable.clearSelection(); // 取消选中
    },
    // 点击树节点
    handleNodeClick(node) {
      this.selectTreeNode = node;
      this.queryTeacherInfo();
    },
    // 查询教师信息
    async queryTeacherInfo() {
      var _this = this;
      var GZBM = this.selectTreeNode.id;
      var keyWord = this.queryKey;
      const res = await jxbgl_query_teacher_list(GZBM, keyWord);
      if (res.data.code == 200) {
        _this.speakerTableData = res.data.data.records;
        if (_this.dialogType == "jxkzj") {
          // 教学课主讲
          _this.classSelectList = _this.jxkZhujiang;
          _this.speakerTableData.forEach((item) => {
            _this.jxkZhujiang.forEach((da) => {
              if (item.id == da.id) {
                _this.$refs.multipleTable.toggleRowSelection(item, true);
              }
            });
          });
          console.log(_this.jxkZhujiang, "_this.jxkZhujiang === ");
        } else {
          // 助教
          _this.classSelectList = _this.jxkZhujiao;
          _this.speakerTableData.forEach((item) => {
            _this.jxkZhujiao.forEach((da) => {
              if (item.id == da.id) {
                _this.$refs.multipleTable.toggleRowSelection(item, true);
              }
            });
          });
        }
      }
    },
    handleSelectionChange(val) {
      this.classSelectList = val;
    },
    //删除标签
    handleClose(tag, inx) {
      this.classSelectList.splice(inx, 1);
      this.$refs.multipleTable.toggleRowSelection(tag);
    },
    // 信息提交
    submitInfo() {
      var params = {
        info: {
          teachingClassName: this.teachingClassName, //教学班名
          courseName: this.courseName,
          courseCharger: this.kcfzr, // 课程负责人
          pointsSystem: this.pointsSystem, //分制
          homeworkRatio: this.homeworkRatio, // 课下作业成绩所占比例
          hskeRatio: this.hskeRatio, // 课堂测试成绩所占比例
          midExamRatio: this.midExamRatio, //期中考试成绩所占比例
          finalExamRetio: this.finalExamRetio, //课终考核成绩所占比例
          teachingMethod: this.teachingMethod, //授课方式
          arrangeReq: this.arrangeReq, //排课要求
          place: this.place,
          placeType: this.jxcslx, // 教学场所类型
          teachingHours: this.teachingHours,
          practiceHours: this.practiceHours,
          totalHours: this.totalHours,
          eduLevel: this.eduLevel,
          credit: this.credit
        },
        extend: {
          khfs: this.khfs,
          teachtask: "",
          assistantemployeeids: "",
          xxlx: this.subjectType
        },
      };
      if (this.jxkZhujiang.length > 0) {
        var zhujiang = [];
        this.jxkZhujiang.forEach((item) => {
          if(item && item.id !='' && item.xm !=''){
            zhujiang.push(item.id + "/" + item.xm);
          }
        });
        params.extend.teachtask = zhujiang.join(",");
      }
      // else {
      //   this.$message.warning("请先选择教学课主讲!");
      //   return;
      // }
      if (this.jxkZhujiao.length > 0) {
        var zhujiao = [];
        this.jxkZhujiao.forEach((item) => {
          if(item && item.id !='' && item.xm !=''){
            zhujiao.push(item.id + "/" + item.xm);
          }
        });
        params.extend.assistantemployeeids = zhujiao.join(",");
      }
      // else {
      //   this.$message.warning("请先选择课助教!");
      //   return;
      // }
      if (this.jxcdcsList.length > 0) {
        params.info.place = this.jxcdcsList[0].id;
      }

      if (this.teachingClassName == "" || this.teachingClassName == null) {
        this.$message.warning("请先填写教学班名称!");
        return;
      }
      if (this.khfs == "" || this.khfs == null) {
        this.$message.warning("请先选择考核方式!");
        return;
      }
      if (this.pointsSystem == "" || this.pointsSystem == null) {
        this.$message.warning("请先选择分制!");
        return;
      }
      // if (this.kcfzr == "" || this.kcfzr == null) {
      //   this.$message.warning("请先选择课程负责人!");
      //   return;
      // }
      if (this.info_type == "edit") {
        params.info.id = this.id;
        params.extend.id = this.id;
        this.updateData(params);
      } else {
        params.info.staffRoom = "";
        params.extend.courseno = this.courseno
        params.info.term = this.xueqi;
        params.info.nj = this.nj;
        this.insertData(params);
      }
    },
    async insertData(params) {
      const res = await jxbgl_teaching_save(params);
      if (res.data.code == 200) {
        this.$message.success("保存成功！");
        this.cancel();
      }
    },
    async updateData(params) {
      const res = await jxbgl_teaching_update(params);
      if (res.data.code == 200) {
        this.$message.success("保存成功！");
        this.cancel();
      }
    },
    async queryCommonDept() {
      const res = await queryCommonDeptByCategory(7);
      if (res.data.code == 200) {
        this.data = res.data.data;
        this.selectTreeNode = this.data[0];
        this.queryTeacherInfo();
      }
    },
    // 取消返回上一页
    cancel() {
      this.$router.push({
        path: "/admin/teachingTaskManage/teachingclass/setTeachingClass",
        query: {
          kcid: this.kcid,
          xueqi: this.xueqi,
          nj: this.nj,
          kcbh: this.kcbh,
        },
      });
    },
    editSpeaker(type) {
      // this.dialogTitle = type;
      this.dialogType = type;
      this.showSpeakerDialog = true;
      this.classSelectList = []
      this.queryCommonDept();
    },
    async queryEditInfo() {
      const res = await jxbgl_query_teaching_class_detail(this.id);
      if (res.data.code == 200) {
        this.courseName = res.data.data.info.courseName;
        this.eduLevel = res.data.data.info.eduLevel;
        this.teachingClassName = res.data.data.info.teachingClassName;
        this.subjectType = res.data.data.extend.xxlx;
        this.totalHours = res.data.data.info.totalHours;
        this.teachingHours = res.data.data.info.teachingHours;
        this.practiceHours = res.data.data.info.practiceHours;
        this.credit = res.data.data.info.credit;
        this.teachingMethod = res.data.data.info.steachingMethod;
        this.kcfzr = res.data.data.info.courseCharger;
        this.khfs = res.data.data.extend.khfs; //考核方式
        this.jxcslx = res.data.data.placeType; // 教学场所类型  ===========
        this.pointsSystem = res.data.data.info.pointsSystem; //分制
        this.homeworkRatio = res.data.data.info.homeworkRatio; // 课下作业成绩所占比例
        this.hskeRatio = res.data.data.info.hskeRatio; // 课堂测试成绩所占比例
        this.midExamRatio = res.data.data.info.midExamRatio; //期中考试成绩所占比例
        this.finalExamRetio = res.data.data.info.finalExamRetio; //课终考核成绩所占比例
        this.arrangeReq = res.data.data.info.arrangeReq; //排课要求
        this.jxcslx = res.data.data.info.placeType; //场地场所类型
        this.place = res.data.data.info.place; //场地
        var teachtask = res.data.data.extend.teachtask.split(",");
        var zhujiangArr = [];
        this.kcfzrList = []
        if (teachtask.length > 0) {
          teachtask.forEach((item) => {
            var a = item.split("/");
            zhujiangArr.push({ id: a[0], xm: a[1] });
            this.kcfzrList.push({ id: a[0], xm: a[1] });
          });
          this.jxkZhujiang = zhujiangArr;
        }

        var assistantemployeeids =
          res.data.data.extend.assistantemployeeids.split(",");
        var zhujiaoArr = [];
        if (assistantemployeeids.length > 0) {
          assistantemployeeids.forEach((item) => {
            var a = item.split("/");
            zhujiaoArr.push({ id: a[0], xm: a[1] });
            this.kcfzrList.push({ id: a[0], xm: a[1] });
          });
          this.jxkZhujiao = zhujiaoArr;
        }
      }
    },
  },
};
</script>

<style scoped lang="less">
.manual-entry-container {
  > div:nth-child(1) {
    width: calc(100% - 20px);
    height: calc(100vh - 250px);
    overflow: auto;
    border: 1px solid rgba(0, 76, 167, 0.8);
    border-radius: 6px;
    margin: 30px auto 0;
    ul {
      list-style: none;
      li {
        border-bottom: 1px solid rgba(0, 76, 167, 0.4);
        height: auto;
        > span {
          text-align: left;
          padding-left: 100px;
          box-sizing: border-box;
          display: inline-block;
          font-size: 14px;
          color: rgba(0, 76, 167, 1);
          padding-left: 54px;
          border-right: 1px solid rgba(0, 76, 167, 0.4);
          height: 60px;
          padding-top: 20px;
          vertical-align: middle;
          &:nth-child(n) {
            width: 357px;
          }
          &:nth-child(2n) {
            width: 444px;
          }
          &:last-child {
            border-right: none;
          }
          &.active {
            font-size: 16px;
            color: rgba(0, 76, 167, 1);
            font-weight: bold;
            background: rgba(77, 129, 192, 0.1);
            text-align: center;
            padding-left: 0;
          }
          > span {
            color: rgba(255, 56, 25, 1);
          }
        }
      }
      &:nth-child(1) {
        li {
          > span {
            text-align: left;
            &.active {
              text-align: left;
              padding-left: 100px;
            }
          }
        }
      }
      &:nth-child(3) {
        li {
          border-bottom: 1px solid rgba(0, 76, 167, 0.4);
          > span {
            width: 400px;
            text-align: center;
            padding-left: 0;
            height: 60px;
            &:nth-child(1) {
              width: 144px;
            }
            &:nth-child(2) {
              width: 180px;
            }
            &:nth-child(3) {
              width: 289px;
            }
            &:nth-child(4) {
              width: 196px;
            }
            &:nth-child(5) {
              width: 197px;
            }
            &:nth-child(6) {
              width: 197px;
            }
            &:nth-child(7) {
              width: 198px;
              padding-top: 8px !important;
              > span {
                display: inline-block;
                width: 121px;
                height: 28px;
                border: 1px solid #5230e9;
                background: rgba(235, 230, 255, 1);
                opacity: 1;
                border-radius: 4px;
                font-size: 14px;
                font-weight: 400;
                color: #5230e9;
                line-height: 18px;
                margin-top: 8px;
                padding: 5px 10px;
                cursor: pointer;
              }
            }
            &:nth-child(8) {
              width: 150px;
            }
            &:nth-child(9) {
              width: 182px;
            }
            &.active {
              border-top: 1px solid rgba(0, 76, 167, 0.4);
              height: 73px;
              padding-top: 25px;
            }
          }
          &:nth-child(2) {
            > div {
              height: 57px;
              padding: 18px 30px;
              > span {
                &:nth-child(1) {
                  font-size: 16px;
                  font-weight: bold;
                  color: #004ca7;
                }
                &:nth-child(2) {
                  font-size: 14px;
                  color: #004ca7;
                }
              }
            }
          }
        }
      }
    }
    > div {
      padding: 14px 83px;
      height: 78px;
      > div:nth-child(1) {
        font-size: 16px;
        font-weight: bold;
        color: #004ca7;
        margin-bottom: 10px;
      }
      > div:nth-child(2) {
        > span {
          font-size: 14px;
          color: rgba(0, 76, 167, 1);
          margin-right: 57px;
          > span {
            color: rgba(255, 56, 25, 1);
          }
        }
      }
    }
  }
  > div:nth-child(2) {
    margin-top: 50px;
    margin-bottom: 30px;
    margin-left: 200px;
    font-size: 18px;
    font-weight: bold;
    color: #004ca7;
  }
}

.edit-icon {
  font-size: 20px;
  color: #02c86c;
  margin-left: 10px;
  cursor: pointer;
}

.del-icon {
  color: #ff492e;
  font-size: 20px;
  margin-left: 10px;
  cursor: pointer;
}

/deep/ .el-tree-node__expand-icon.expanded {
  color: rgb(0, 76, 167);
}

.border-left {
  .assessment-container {
    .search-container {
      flex-direction: row;
      justify-content: space-between;
      .search-container-left {
        display: flex;
        flex-direction: row;
      }
      .search-container-right {
        display: flex;
        flex-direction: row;

        justify-content: flex-end;
        margin-top: 17px;
      }
      .search-container-item {
        color: #004ca7;
        font-size: 16px;
        font-family: Microsoft YaHei;
        font-weight: 400;
        margin-right: 30px;
        > span {
          margin-right: 6px;
        }
      }
      .search-button {
        width: 77px;
        height: 28px;
        line-height: 28px;
        background: #f1f8fe;
        border: 1px solid #51aef6;
        border-radius: 6px;
        cursor: pointer;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: center;
        > span {
          font-size: 16px;
          font-family: Microsoft YaHei;
          font-weight: 400;
          color: #51aef6;
        }
        > img {
          width: 20px;
          height: 20px;
          margin-right: 4px;
        }
      }
    }
    // width: calc(100% - 40px);
    // margin: 20px;
    // margin-top: 0;
    /deep/ .table-container {
      width: 100% !important;
      .el-table td,
      .el-table th.is-leaf,
      .el-table--border,
      .el-table--group {
        border-color: #c7d7eb;
      }

      .el-table__header tr,
      .el-table__header th {
        padding: 0;
        height: 76px;
        background-color: #edf2f9;
        font-size: 16px;
        font-family: Microsoft YaHei;
        font-weight: bold;
        line-height: 20px;
        color: #004ca7;
      }

      .el-table__body tr,
      .el-table__body td {
        padding: 0;
        height: 86px;
      }

      .table-data {
        width: 100%;
        border: 0.8px solid #004ca7;
        border-radius: 9px;
        font-size: 14px;
        font-family: Microsoft YaHei;
        font-weight: 400;
        color: #004ca7;
      }
    }
  }
}

.btn-caozuo {
  display: flex;
  align-items: center;
  justify-content: space-around;
  width: 800px;
  margin: 0 auto;
  padding-top: 50px;
}

/deep/ .el-input--small .el-input__inner {
  height: 28px;
  width: 200px;
}

.jxkzj {
  /deep/ .el-dialog {
    height: 650px;
  }
}

.xz_jxkzj {
  /deep/ .el-dialog {
    height: 880px;
  }
}
</style>

<style lang="less" scoped>
  #edit-teach-class-info{
    /deep/ .el-button--warning.is-plain{
      background: #FFF6EF;
      border-color: #F3B815;
      color: #F3B815;
      border-radius: 6px;
    }
    /deep/ .el-button--warning.is-plain:focus, .el-button--warning.is-plain:hover{
      color: #F3B815;
      background: #FFF6EF;
      border: 1px solid #F3B815;
      border-radius: 6px;
    }

    /deep/ .el-button--success.is-plain{
      background: #F1FFF8;
      border-color: #02C86C;
      color: #02C86C;
      border-radius: 6px;
    }
    /deep/ .el-button--success.is-plain:hover{
      background: #F1FFF8;
      border: 1px solid #02C86C;
      color: #02C86C;
      border-radius: 6px;
    }

    /deep/ .el-button--primary.is-plain{
      background: #F1F8FE;
      border-color: #51AEF6;
      color: #51AEF6;
      border-radius: 6px;
    }

    /deep/ .el-button--primary.is-plain:hover{
      background: #F1F8FE;
      border: 1px solid #51AEF6;
      color: #51AEF6;
      border-radius: 6px;
    }

    /deep/ .el-button--danger.is-plain{
      background: #FFEFEF;
      border-color: #FF3819;
      color: #FF3819;
      border-radius: 6px;
    }

    /deep/ .el-button--danger.is-plain:hover{
      background: #FFEFEF;
      border: 1px solid #FF3819;
      color: #FF3819;
      border-radius: 6px;
    }
  }
</style>
